<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>实现仿天猫商品展示效果</title>
    <style>
        body {
            background-color: #ddd;
        }

        .main {
            margin: 100px auto;
            width: 800px;
            clear: both;
        }

        .main li {
            list-style: none;
            width: 240px;
            padding: 1px;
            border: 1px solid rgba(255, 0, 0, 0);
            cursor: pointer;
            background-color: #fff;
            float: left;
            margin: 3px;
        }

        .main li:hover {
            border: 1px solid rgba(255, 0, 0, 1);
        }

        .main li:hover .img img {
            opacity: 0.7;
        }

        .img img {
            width: 240px;
            transition: all 1s;
        }

        .goods-title {
            margin: 10px;
            color: #666;
            height: 45px;
            overflow: hidden;
        }

        .price {
            margin: 10px;
            color: #f00;
        }
    </style>
</head>
<body>
    <div class="main">
        <ul>
            <li>
                <div class="img">
                    <img src="../images/goods/uav.png" alt="uav">
                </div>
                <div class="goods-title">【预售】DJI 大疆 御 Mavic Air 便携可折叠4K无人机 高清航拍</div>
                <div class="price">¥ 4999.00-6898.00</div>
            </li>

            <li>
                    <div class="img">
                        <img src="../images/goods/dsh.jpg" alt="dsh">
                    </div>
                    <div class="goods-title">美的电热水壶家用304不锈钢正品电热烧水壶自动断电大容量开水壶</div>
                    <div class="price">¥ 79.00</div>
                </li>
        </ul>
    </div>
</body>
</html>